package cn.zust.ly.EyExample.Ey06;

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int a[] = new int[n];
		a[0] = 1;
		System.out.println(a[0]+" ");
		for (int i = 1; i < n; i++) {
			int ii = i+1;
			for (int j = ii/2 + ii%2; j > 0; j--) {
				a[j] = a[j] + a[j-1];
			}
			for (int j = ii/2; j < ii; j++) {
				a[j] = a[i-j];
			}
			for (int j = 0; j < ii; j++) {
				System.out.print(a[j]+" ");
			}
			System.out.println();
		}
		
	}
}
